<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<TITLE>
DRA Systems: OR-Objects 1.2.4: Class  StepwiseLinear
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">

<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT ID="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT ID="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT ID="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT ID="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT ID="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT ID="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../drasys/or/stat/model/ReverseLinear.html"><B>PREV CLASS</B></A>&nbsp;
&nbsp;NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="StepwiseLinear.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#fields_inherited_from_class_drasys.or.stat.model.LinearRegression">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: &nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
drasys.or.stat.model</FONT>
<BR>
Class  StepwiseLinear</H2>
<PRE>
java.lang.Object
  |
  +--<A HREF="../../../../drasys/or/stat/model/LinearRegression.html">drasys.or.stat.model.LinearRegression</A>
        |
        +--<B>drasys.or.stat.model.StepwiseLinear</B>
</PRE>
<HR>
<DL>
<DT>public class <B>StepwiseLinear</B><DT>extends <A HREF="../../../../drasys/or/stat/model/LinearRegression.html">LinearRegression</A><DT>implements <A HREF="../../../../drasys/or/stat/model/LinearRegressionI.html">LinearRegressionI</A></DL>

<P>
A stepwise multiple linear regression model.
This algorithm starts by selecting all of the required variables.
A non-selected variable is a candidate for entry if it is in the set 'enteringVariables' and if its p-value after addition is less than 'enterPValue'.
The algorithm adds the entering candidate with the lowest potential p-value.
A selected varable is a candidate for removal if its p-value exceeds 'exitPValue' and it isn't a required variable.
The algorithm removes the candidate with the highest p-value and solves the model with the new set of variables.
After adding each entering variable the algorithm continues removing candidates until all p-values are below 'exitPValue'.
Then it adds the next entering variable and continues until there are no more entering candidates.
<P><FONT COLOR="#CC0000"><FONT SIZE=+1>References:</FONT></FONT><FONT SIZE=+1></FONT><P><B><A NAME="0256117365"HREF="http://www.amazon.com/exec/obidos/ISBN=0256117365/opsresearchcomA/" TARGET="amazon.com">Applied Linear Statistical Models (Irwin Series in Statistics)</A></B><BR>&nbsp;&nbsp;&nbsp;&nbsp;Michael H. Kutner, et al / Hardcover / Published 1996<BR><B><A NAME="0521431085"HREF="http://www.amazon.com/exec/obidos/ISBN=0521431085/opsresearchcomA/" TARGET="amazon.com">Numerical Recipes in C : The Art of Scientific Computing</A></B><BR>&nbsp;&nbsp;&nbsp;&nbsp;William H. Press, et al / Hardcover / Published 1993<BR>
<P>
<HR>

<P>
<!-- ======== INNER CLASS SUMMARY ======== -->


<!-- =========== FIELD SUMMARY =========== -->

<A NAME="fields_inherited_from_class_drasys.or.stat.model.LinearRegression"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Fields inherited from class drasys.or.stat.model.<A HREF="../../../../drasys/or/stat/model/LinearRegression.html">LinearRegression</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_cfstat">_cfstat</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_coef">_coef</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_cov">_cov</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_dependent">_dependent</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_enteringVariables">_enteringVariables</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_enterPValue">_enterPValue</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_exitPValue">_exitPValue</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_glm">_glm</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_independent">_independent</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_lastConfidenceLevel">_lastConfidenceLevel</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_lower">_lower</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_m">_m</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_n">_n</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_requiredVariables">_requiredVariables</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_selectedVariables">_selectedVariables</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_stdv">_stdv</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_tpvalue">_tpvalue</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_tstat">_tstat</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_upper">_upper</A>,  
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#_zeroIntercept">_zeroIntercept</A></CODE></TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->

<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../drasys/or/stat/model/StepwiseLinear.html#StepwiseLinear(drasys.or.stat.model.GeneralLinearModelI)">StepwiseLinear</A></B>(<A HREF="../../../../drasys/or/stat/model/GeneralLinearModelI.html">GeneralLinearModelI</A>&nbsp;glm)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Initialize the regression with an explicit general linear model.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../drasys/or/stat/model/StepwiseLinear.html#StepwiseLinear(drasys.or.matrix.VectorI, drasys.or.matrix.MatrixI)">StepwiseLinear</A></B>(<A HREF="../../../../drasys/or/matrix/VectorI.html">VectorI</A>&nbsp;dependent,
               <A HREF="../../../../drasys/or/matrix/MatrixI.html">MatrixI</A>&nbsp;independent)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Initialize the regression with the sample data.</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../drasys/or/stat/model/StepwiseLinear.html#solve()">solve</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Solve for the significant variables and coefficients.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../drasys/or/stat/model/StepwiseLinear.html#toString()">toString</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a string representation of this object.</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_drasys.or.stat.model.LinearRegression"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class drasys.or.stat.model.<A HREF="../../../../drasys/or/stat/model/LinearRegression.html">LinearRegression</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../drasys/or/stat/model/LinearRegression.html#allVariables()">allVariables</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getCoefficients()">getCoefficients</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getEnteringThreshold()">getEnteringThreshold</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getEnteringVariables()">getEnteringVariables</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getExitingThreshold()">getExitingThreshold</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getF()">getF</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getFPV()">getFPV</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getGLM()">getGLM</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getLowerBounds(double)">getLowerBounds</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getRequiredVariables()">getRequiredVariables</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getSelectedVariables()">getSelectedVariables</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getT()">getT</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getTPV()">getTPV</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getTStatistic(double)">getTStatistic</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#getUpperBounds(double)">getUpperBounds</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#setEnteringThreshold(double)">setEnteringThreshold</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#setEnteringVariables(int[])">setEnteringVariables</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#setExitingThreshold(double)">setExitingThreshold</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#setRequiredVarables(int[])">setRequiredVarables</A>, 
<A HREF="../../../../drasys/or/stat/model/LinearRegression.html#setSelectedVariables(int[])">setSelectedVariables</A></CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, 
equals, 
finalize, 
getClass, 
hashCode, 
notify, 
notifyAll, 
wait, 
wait, 
wait</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ FIELD DETAIL =========== -->


<!-- ========= CONSTRUCTOR DETAIL ======== -->

<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="StepwiseLinear(drasys.or.matrix.VectorI, drasys.or.matrix.MatrixI)"><!-- --></A><H3>
StepwiseLinear</H3>
<PRE>
public <B>StepwiseLinear</B>(<A HREF="../../../../drasys/or/matrix/VectorI.html">VectorI</A>&nbsp;dependent,
                      <A HREF="../../../../drasys/or/matrix/MatrixI.html">MatrixI</A>&nbsp;independent)</PRE>
<DL>
<DD>Initialize the regression with the sample data.
The model will use 'GeneralLinearModel' for the underlying GLM algorithm.</DL>
<HR>

<A NAME="StepwiseLinear(drasys.or.stat.model.GeneralLinearModelI)"><!-- --></A><H3>
StepwiseLinear</H3>
<PRE>
public <B>StepwiseLinear</B>(<A HREF="../../../../drasys/or/stat/model/GeneralLinearModelI.html">GeneralLinearModelI</A>&nbsp;glm)</PRE>
<DL>
<DD>Initialize the regression with an explicit general linear model.
The GLM should be initialized with the sample data.</DL>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>

<A NAME="solve()"><!-- --></A><H3>
solve</H3>
<PRE>
public int <B>solve</B>()</PRE>
<DL>
<DD>Solve for the significant variables and coefficients.
Returns the number of independent variables selected in the final model.
This algorithm uses 'setSelectedVariables' to solve the model and will leave the final solution variables selected.
The solution can be retrieved with 'getSelectedVariables' and the column indices will be in ascending order.<DD><DL>
<DT><B>Specified by: </B><DD><A HREF="../../../../drasys/or/stat/model/LinearRegressionI.html#solve()">solve</A> in interface <A HREF="../../../../drasys/or/stat/model/LinearRegressionI.html">LinearRegressionI</A></DL>
</DD>
</DL>
<HR>

<A NAME="toString()"><!-- --></A><H3>
toString</H3>
<PRE>
public java.lang.String <B>toString</B>()</PRE>
<DL>
<DD>Creates a string representation of this object.
The string is composed of 'super.toString()' followed by the details of the iterations used to solve the regression.<DD><DL>
<DT><B>Overrides:</B><DD><A HREF="../../../../drasys/or/stat/model/LinearRegression.html#toString()">toString</A> in class <A HREF="../../../../drasys/or/stat/model/LinearRegression.html">LinearRegression</A></DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>

<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT ID="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT ID="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT ID="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT ID="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT ID="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT ID="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../drasys/or/stat/model/ReverseLinear.html"><B>PREV CLASS</B></A>&nbsp;
&nbsp;NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="StepwiseLinear.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY: &nbsp;INNER&nbsp;|&nbsp;<A HREF="#fields_inherited_from_class_drasys.or.stat.model.LinearRegression">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: &nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->

<HR>
Copyright(C)1997-2000 by DRA Systems all rights reserved. <A HREF=http://OpsResearch.com TARGET=HOME>OpsResearch.com</A>
</BODY>
</HTML>
